HTML_QuickForm2
[ class tree: HTML_QuickForm2 ] [ index: HTML_QuickForm2 ] [ all elements ]

Class: HTML_QuickForm2_Element_Button

Source Location: /HTML_QuickForm2-0.1.0/QuickForm2/Element/Button.php

Class Overview

HTML_Common2
   |
   --HTML_QuickForm2_Node
      |
      --HTML_QuickForm2_Element
         |
         --HTML_QuickForm2_Element_Button

Class for <button> elements


Author(s):

Version:

  • Release: 0.1.0

Variables

Methods


Inherited Variables

Inherited Methods

Class: HTML_QuickForm2_Element

HTML_QuickForm2_Element::getId()
HTML_QuickForm2_Element::getName()
HTML_QuickForm2_Element::getPersistentContent()
Generates hidden form field containing the element's value
HTML_QuickForm2_Element::onAttributeChange()
HTML_QuickForm2_Element::setId()
HTML_QuickForm2_Element::setName()
HTML_QuickForm2_Element::updateValue()
Called when the element needs to update its value from form's data sources

Class: HTML_QuickForm2_Node

HTML_QuickForm2_Node::__construct()
Class constructor
HTML_QuickForm2_Node::generateId()
Generates an id for the element
HTML_QuickForm2_Node::getContainer()
Returns the element containing current
HTML_QuickForm2_Node::getDataSources()
Returns the data sources for this element
HTML_QuickForm2_Node::getId()
Returns the element's id
HTML_QuickForm2_Node::getLabel()
Returns the element's label(s)
HTML_QuickForm2_Node::getName()
Returns the element's name
HTML_QuickForm2_Node::getType()
Returns the element's type
HTML_QuickForm2_Node::getValue()
Returns the element's value
HTML_QuickForm2_Node::persistentFreeze()
Changes the element's persistent freeze behaviour
HTML_QuickForm2_Node::setContainer()
Adds the link to the element containing current
HTML_QuickForm2_Node::setId()
Sets the elements id
HTML_QuickForm2_Node::setLabel()
Sets the element's label(s)
HTML_QuickForm2_Node::setName()
Sets the element's name
HTML_QuickForm2_Node::setValue()
Sets the element's value
HTML_QuickForm2_Node::storeId()
Stores the explicitly given id to prevent duplicate id generation
HTML_QuickForm2_Node::toggleFrozen()
Changes the element's frozen status
HTML_QuickForm2_Node::updateValue()
Called when the element needs to update its value from form's data sources

Class Details

[line 63]
Class for <button> elements

Note that this element was named 'xbutton' in previous version of QuickForm, the name 'button' being used for current 'inputbutton' element.



[ Top ]


Class Variables

$data = array('content' => '')

[line 70]

Contains options and data used for the element creation

  • content: Content to be displayed between <button></button> tags

  • Access: protected

Type:   array
Overrides:   Array


[ Top ]

$submitValue =  null

[line 76]

Element's submit value
  • Access: protected

Type:   string


[ Top ]



Method Detail

getType   [line 79]

void getType( )

  • Access: public

Overrides HTML_QuickForm2_Node::getType() (Returns the element's type)
[ Top ]

getValue   [line 128]

string|null getValue( )

Returns the element's value

The value is only returned if the following is true

  • button has 'type' attribute set to 'submit' (or no 'type' attribute)
  • the form was submitted by clicking on this button
This method returns the actual value submitted by the browser. Note that different browsers submit different values!

  • Access: public

Overrides HTML_QuickForm2_Node::getValue() (Returns the element's value)
[ Top ]

setContent   [line 101]

void setContent( string $content)

Sets the contents of the button element

Parameters:

string   $content   —  Button content (HTML to add between <button></button> tags)

[ Top ]

setValue   [line 111]

void setValue( mixed $value)

Button's value cannot be set via this method
  • Access: public

Overrides HTML_QuickForm2_Node::setValue() (Sets the element's value)

Parameters:

mixed   $value   —  Element's value, this parameter is ignored

[ Top ]

toggleFrozen   [line 91]

bool toggleFrozen( [bool $freeze = null])

Buttons can not be frozen
  • Return: Always returns false
  • Access: public

Overrides HTML_QuickForm2_Node::toggleFrozen() (Changes the element's frozen status)

Parameters:

bool   $freeze   —  Whether element should be frozen or editable. This parameter is ignored in case of buttons

[ Top ]

updateValue   [line 145]

void updateValue( )

  • Access: protected

Overrides HTML_QuickForm2_Element::updateValue() (Called when the element needs to update its value from form's data sources)
[ Top ]

__toString   [line 139]

void __toString( )

  • Access: public

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:00:13 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.